package com.deltabot;

import com.deltabot.logging.Log;
import com.deltabot.networking.Tools;
import com.deltabot.networking.update.UpdateCheck;
import com.deltabot.settings.Client;

public class Boot {

    public static void main(String[] args) {

        for(String argument : args){
            handleArgument(argument);
        }

        Log.info("Welcome to deltaBot [revision " + Client.REVISION + "]");
        Log.info("Checking for updates...");

        if(UpdateCheck.newVersionAvailable()){
            Log.warning("A new version of deltaBot is available, please consider upgrading");
        }

    }

    static void handleArgument(String argument){

        switch (argument){

            case "+developer":
                Client.developerMode = true;
                break;

            default: Log.info("Invalid argument: " + argument);

        }

    }

}
